#include"SeqList.h"
void SLTest1()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	SLPushBack(&s, 5);
	SLPushBack(&s, 6);


	SLPrint(&s);
	SLDestroy(&s);
}
void SLTest2()
{
	SL s;
	SLInit(&s);
	SLPushFront(&s, 1);
	SLPushFront(&s, 2);
	SLPushFront(&s, 3);
	SLPushFront(&s, 4);
	SLPushFront(&s, 5);
	SLPushFront(&s, 6);
	SLPushFront(&s, 7);

	SLPrint(&s);
	SLDestroy(&s);
}
void SLTest3()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushFront(&s, 4);
	SLPushFront(&s, 5);
	SLPushFront(&s, 6);


	SLPrint(&s);
	SLDestroy(&s);
}

void SLTest4()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushFront(&s, 4);
	SLPushFront(&s, 5);
	SLPushFront(&s, 6);

	SLPopBack(&s);
	SLPopFront(&s);
	SLPopFront(&s);


	SLPrint(&s);
	SLDestroy(&s);
}

void SLTest5()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	SLPushFront(&s, 5);
	SLPushFront(&s, 6);
	SLPushFront(&s, 7);

	SLPopBack(&s);
	SLPopFront(&s);
	SLPopFront(&s);


	SLPrint(&s);
	SLDestroy(&s);
}

void SLTest6()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	SLPushFront(&s, 5);
	SLPushFront(&s, 6);
	SLPushFront(&s, 7);

	int pos=SLFind(&s, 4);
	if (pos != -1)
	{
		SLErase(&s, pos);
	}

	 SLPrint(&s);
	 SLDestroy(&s);

}

int main()
{

	SLTest6();
	SL s;
	SLInit(&s);

	return 0;
}